Release 10.1A: OpenEdge Data Management:
SQL Reference
Preface
This Preface contains the following sections:
Purpose
OpenEdge Data Management: SQL Reference provides specific information on the OpenEdge® SQL language. The reference contains information on SQL statements, functions, reserved words, error messages, data type compatibility, and the language’s compliance with industry standards. The book also provides reference information on the ODBC and JDBC drivers.
Audience
The audience of this book is composed of two groups:
Organization
Describes the purpose and syntax of each OpenEdge SQL statement. A sample is provided for each statement.
Describes the purpose and syntax of each OpenEdge SQL function. A sample is provided for each function.
Provides a list of words that have special syntactic meaning to OpenEdge SQL and cannot be used as identifiers for constants, variables, cursors, types, tables, records, subprograms or packages.
Provides a list of error messages generated by the various components of OpenEdge SQL.
Provides a list of the maximum sizes for various attributes of the OpenEdge SQL database environment, and for elements of SQL queries addressed to this environment.
OpenEdge SQL System Catalog Tables
Provides a set of system tables for storing information about tables, columns, indexes, constraints, and privileges. This chapter describes those system catalog tables.
Addresses compatibility issues when using OpenEdge SQL and earlier versions of the Progress database.
OpenEdge SQL Language Elements
Describes Standard SQL language elements that are common to OpenEdge SQL.
Support for the Array Data Type
Details OpenEdge SQL support for 4GL
ARRAYdata type, including thePRO_ELEMENT,PRO_ARR_ESCAPE, andPRO_ARR_DESCAPEfunctions.OpenEdge SQL Elements and Statements in Backus Naur Form
Presents OpenEdge SQL elements and statements in Backus Naur Form.
Compliance with Industry Standards
Addresses compatibility issues when using OpenEdge SQL and earlier versions of its database.
Lists and describes SQL keywords to use with statements that allow you to define 4GL attributes for tables and columns.
Provides information on OpenEdge SQL Java classes and methods.
Provides information on mapping between JDBC and other data types and return values for database metadata.
OpenEdge SQL and ODBC Data Types
Shows how the OpenEdge data types are mapped to the standard ODBC data types.
Describes return values to SQL GetInfo from the ODBC driver.
Lists scalar functions that ODBC supports and are available to use in SQL statements.
Provides reference information for an ESQL interface.
Typographical conventions
This manual uses the following typographical conventions:
Examples of syntax diagrams (SQL)
In this example,
GRANT,RESOURCE,DBA, andTOare keywords. You must specifyRESOURCE,DBA, or both, and at least oneuser_name. Optionally you can specify additionaluser_nameitems; each subsequentuser_namemust be preceded by a comma:
This excerpt from an ODBC application invokes a stored procedure using the ODBC syntax {
callprocedure_name( param )}, where braces and parentheses are part of the language:
In this example, you must specify a
table_name,view_name, orsynonym, but you can choose only one. In all SQL syntax, if you specify the optionalowner_namequalifier, there must not be a space between the period separator andtable_name,view_name, orsynonym:
In this example, you must specify
table_nameorview_name:
In this example, you must include one expression
(expr)or column position(posn), and optionally you can specify the sort order as ascending (ASC) or descending (DESC). You can specify additional expressions or column positions for sorting within a sorted result set. The SQL engine orders the rows on the basis of the firstexprorposn. If the values are the same, the secondexprorposnis used in the ordering:
Long syntax descriptions split across lines
Some syntax descriptions are too long to fit on one line. When syntax descriptions are split across multiple lines, groups of optional and groups of required items are kept together in the required order.
In this example,
CREATE VIEWis followed by several optional items:
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |